'use strict';
import * as fs from "fs";

export function jcprint(message?: any) {
    //console.log(message);
    //fs.writeFileSync("d:\\typescript\\dbginfo.txt", message + "\r\n", { flag: "a+" });
}

export function repeat(s: string, n: number = 1) {
    for (let i = 0; i < n; ++i) s += s;
    return s;
}

export function strendswith(s: string, t: string) {
    return (s.lastIndexOf(t) == (s.length - t.length));
}

export function strstartswith(s: string, t: string) {
    return (s.indexOf(t) == 0);
}

